﻿using RulesEngine;

namespace NUnitTest.VipRules.Validation.Rules
{
    public class VipStatusRule : CompositeRule<INewVipCandidate>, INewVipRule
    {
        public int MonthIndex { get; set; }
        public short StartStatus { get; set; }
        public short EndStatus { get; set; } 
        public bool IsPass { get; set; }
        public short ActiveStatus { get; set; }

        public override bool Execute(INewVipCandidate candidate)
        {
            var result = CheckStatus(candidate.UserID, candidate.EffectiveDate.AddMonths(this.MonthIndex));

            return this.SetValidateResult(result, candidate);
        }

        private bool CheckStatus(long contactId, DateTime effectiveMonth)
        { 
            return true;
        }
    }
}